#include "WindowSensor.h"

 int winstate = 0;//0 refers to window closed, 1 refers to window opened.
 void windowSensor(){
    int windowState = digitalRead(windowSensorPin);
    if(windowState == LOW){
       winstate = 0;
    }
    else{
       winstate = 1;
    }
  }

 int windowState(){
  return winstate;
 }
 void windowinit(){
    pinMode(windowSensorPin, INPUT);
 }
